<script lang="ts" setup>
import { get, post, message, loadFile } from '@/utils'
import { FormInstance } from '@arco-design/web-vue'
const props = defineProps<{
  show: boolean
  info: any
}>()
const emit = defineEmits(['update:show', 'reset', 'confirm'])
const formRef = ref() as Ref<FormInstance>
const detail = reactive({
  parentId: '',
  parentAvatar: '',
  parentNickName: '',
  parentMobile: '',
})

const getInfo = () => {
  Object.assign(detail, props.info)
}
onMounted(() => {
  getInfo()
})
</script>
<template>
  <CModal v-model:visible="props.show" :footer="false" width="500px" title="查看上级" @cancel="emit('update:show', false)">
    <div class="content">
      <a-form :model="detail" ref="formRef" :label-col-props="{ span: 6 }" :wrapper-col-props="{ span: 16 }">
        <a-form-item label="上级头像" extra="1:1">
          <Upload v-model:value="detail.parentAvatar" :list="detail.parentAvatar" disabled />
        </a-form-item>
        <a-form-item label="上级ID">
          <a-input readonly v-model="detail.parentId" placeholder="请输入上级ID" />
        </a-form-item>

        <a-form-item label="上级昵称">
          <a-input readonly v-model="detail.parentNickName" placeholder="请输入上级昵称" />
        </a-form-item>
        <a-form-item label="联系方式">
          <a-input readonly v-model="detail.parentMobile" placeholder="请输入联系方式" />
        </a-form-item>
      </a-form>
    </div>
  </CModal>
</template>
<style lang="less" scoped></style>
